#ifndef _BYTEBUFFER_H
#define _BYTEBUFFER_H

#pragma once

#include <string>
#include <sstream>

class ByteBuffer
{
public:
	ByteBuffer();
	virtual ~ByteBuffer();

	void put(const std::string& str);
	void put(const char* bytes, size_t bytesLength);
	void put(int);

	const char* get() const;
	std::string getAll();

	size_t size() const;

	void clear();
private:
	std::string buffer;
	size_t length;
};

#endif
